<link rel="stylesheet" type="text/css" href="/Public/client/css/index.css">
<link rel="stylesheet" type="text/css" href="/Public/client/css/content.css">
<link rel="stylesheet" type="text/css" href="/Public/client/css/ngDialog.css">
<section class="content-wrap" ng-controller = "contentCtr">
    <div class="container">
        <div class="row">
            <main class="col-md-8 main-content">
                <article id="70" class="post">
                    <header class="post-head">
                        <h1 class="post-title">{{result.post_title}}</h1>
                        <section class="post-meta">
                            <span class="author">
                                作者：
                                <a href="javascript:;">{{result.post_admin}}</a>
                            </span>
                            •
                            <time class="post-date">{{result.post_createtime}}</time>
                            •
                            <span>{{result.goodCount}} 赞</span>
                        </section>
                    </header>                   
                    <section class="post-content">                       
                    </section>  
                    <div class="post-permalink">
                        <a href="javascript:;" ng-click="good(result)" class="iconfont icon-good {{result.isGood}}" title="很好"></a>
                    </div>  
                    <section class="comment-main">
                        <div class="comment-title">{{result.comments.length}}条评论</div>
                        <div class="comment-con">
                            <div class="me-comment">
                                <div class="me-con {{uid ? 'is-login' : '' }}">
                                    <img src="{{result.photo}}"/>   
                                    <input type="text" ng-model="meText" ng-focus="isShow = 'is-show';" ng-trim="true" required>
                                    <div class="comment-btns {{isShow}}">
                                        <a href="javascript:;" ng-click="isShow = ''" class="cancel-btn">取消</a>
                                        <a href="javascript:;" class="submit-con {{meText ? 'able' : ''}}" ng-click= "comment(false, result.username, '', result.photo, uid)">评论</a>
                                    </div>
                                </div>
                            </div>
                            <div class="comment-list" infinite-scroll='loadComment(result.post_id)' infinite-scroll-distance='2'>
                                <div class="comment-item" ng-repeat="item in result.comments">
                                    <div class="person-title cc">
                                        <img class="photo" src="{{item.comment_photo}}">
                                        <a href="javascript:;" class="name">{{item.comment_username}}</a> 
                                        <span href="javascript:;" class="reply {{item.comment_author != '' ? 'is-show' : ''}}">
                                            <span>回复了</span> 
                                            <a href="javascript:;" class="other-name">{{item.comment_author}}</a>
                                        </span>
                                        <a href="javascript:;" ng-if="item.comment_uid == uid" class="del-comment" ng-click="delComment(item.comment_id)">删除</a>
                                    </div>
                                    <div class="person-replay">
                                        <div class="reply-con">{{item.comment_text}}</div>
                                        <div class="reply-about"> 
                                            <!-- <time>{{item.comment_date}}</time>  -->
                                            <a href="javascript:;" class="reply-this" ng-click="nowIndex['index'+$index] = 'is-show'"><i></i>回复</a>
                                            <a href="javascript:;" ng-click="commentGood(item)" class="reply-good {{item.isCommentGood}}"><i class="iconfont icon-good"></i> 赞 </a>
                                            <span class="fr">{{item.comment_good_count}} 赞</span>
                                            <div class="form {{nowIndex['index'+$index]}} {{uid ? 'is-login' : ''}}">
                                                <img class="person-p" src="{{result.photo}}">
                                                <input type="text" ng-model="metext['text'+$index]">
                                                <div class="comment-btns">
                                                    <a href="javascript:;" class="cancel-btn" ng-click="nowIndex['index'+$index] = ''">取消 </a>
                                                    <a href="javascript:;" class="submit-con {{metext['text'+$index] ? 'able' : ''}}" ng-click="comment($index, result.username, item.comment_username, result.photo, uid, item.comment_id)">评论</a>
                                                </div>
                                            </div>
                                        </div>
                                    </div>
                                </div>
                            </div>
                            <div class="no-more pt30">{{noMore}}</div>
                        </div>
                    </section>                  
                </article>                           
            </main>
            <aside class="col-md-4 sidebar">
                <div class="widget">
                    <h4 class="title">墓志铭</h4>
                    <div class="content community">
                        <p>旧时几多事，都付笑谈中</p>                     
                    </div>
                </div>
            </aside>
        </div>
    </div>
</section>

